import request from '@/utils/requestPro';


/**
 * 司机 列表
 * @param pram
 */
export function getDriverListApi(params) {
	return request({
		url: `/admin/merchant/deliveryDriver/page`,	
		method: 'get',
		params,
	});
}

// 添加配送司机
export function saveDriverApi(data) {
	return request({
		url: `/admin/merchant/deliveryDriver/save`,	
		method: 'POST',
		data,
	});
}

/** 修改配送司机 */
export function upDateDriverApi(data) {
	return request({
		url: `/admin/merchant/deliveryDriver/updateById`,	
		method: 'PUT',
		data,
	});
}

/** 删除配送司机 */
export function delDriverApi(params) {
	return request({
		url: `/admin/merchant/deliveryDriver/deleteById`,	
		method: 'DELETE',
		params,
	});
}

/** 设置为默认，配送司机 */
export function setDefaultDriverApi(params) {
	return request({
		url: `/admin/merchant/deliveryDriver/setDefault`,	
		method: 'PUT',
		params,
	});
}

/**
 * 交货进度 列表
 * @param pram
 */
export function getProgressListApi(params) {
	return request({
		url: `/admin/merchant/deliveryProgress/getProgressRecordList`,	
		method: 'get',
		params,
	});
}

/**
 * 交货进度详情分页
 * @param pram
 */
export function getProgressDetilApi(params) {
	return request({
		url: `/admin/merchant/deliveryProgress/getProgressDetailsPage`,	
		method: 'get',
		params,
	});
}

/**
 * 查询收货记录列表
 * @param pram
 */
export function getReceivingListApi(params) {
	return request({
		url: `/admin/merchant/deliveryProgress/getReceivingRecordList`,	
		method: 'get',
		params,
	});
}

// 交货进度修改司机信息
export function upDateDriveryApi(data) {
	return request({
		url: `/admin/merchant/deliveryProgress/updateDeliveryDriverInfo`,	
		method: 'POST',
		data,
	});
}